home
***
CD-ROM
|
disk
|
FTP
|
other
***
search
/
Business Assistant
/
Business Assistant.iso
/
indus
/
rental
/
manage.prg
< prev
next >
Wrap
Text File
|
1986-05-31
|
13KB
|
347 lines
** Last revision: May 27, 1986 at 20:58
* MANAGE.PRG
*
* This is a highly complicated program and your help in both clearing
* up the bugs and making suggestions will be appreciated. My thanks to the
* many people who helped test and revise this program - and especially to
* Lee Hillard for some great code and for his pretty print and dBASE syntax
* checker program. Lee is at Hilco Software, 304 N. 17th St., Mt. Vernon
* WA 98273. (206) 428-0475. I might add that the coded portion of the program
* was done using RECODE by Hilco. However, there is no way that we could
* fully test this program without extensive field work. Most of the changes
* from this point on should be relatively simple - so if you are using the
* program, please drop me a note. We will try to let you know of changes
* as they develop, either via a note or a new SIG/M release. If you find a
* bug or a requirement for the program, please let us know.
*
* April 1986
* After receiving many requests I finally did a conversion of this
* program from dBASEII to dBASEIII. This is the converted version. It
* really has not been tested - so please drop me a card on any problems
* you find.
*
* Please contact:
* Stephen M. Leon
* 200 Winston Drive
* Cliffside Park, NJ 07010
* (201) 886-1658
* or
* Department of Law
* 2 World Trade Center
* New York, NY 10047
* (212) 488-7677
*******************************************************************************
* *
* N O T I C E *
* *
* Copyright 1984,86 by STEPHEN M.LEON. Non-commercial use or distribution *
* of the program is authorized only if this notice is retained together with *
* the text relating to acceptance of the terms of this notice, and the person *
* or persons using the program or benefiting therefrom assume all direct or *
* indirect risks of such use and agree to indemnify the author and the not- *
* for-profit computer clubs distributing this program, from any direct or *
* or indirect expenses incurred by them as a result of their use thereof. *
* Expenses shall include reasonable counsel fees including reasonable fees *
* of the author in his capacity as an attorney for services on a reasonable *
* billing time basis rendered to himself in his capacity as the holder of *
* the copyright. Any use of this program constitutes an agreement to the *
* conditions of this license. Any other use or distribution is unauthorized *
* and prohibited without the express written consent of the author. *
* *
* This program is distributed free (for a nominal media charge) by SIG/M *
* Special Interest Group/Microcomputers, Box 97, Iselin, NJ 08830. *
* SIG/M is a not-for-profit undertaking of the Amateur Computer Group of New *
* Jersey and the New York Amateur Computer Club. This program is also made *
* available for PC users via PC/BLUE SOFTWARE, also a not-for profit under- *
* taking of the New Jersey and New York clubs. Permission is granted to any *
* other not-for-profit group to include this program in their library so long *
* as this notice is retained and the conditions set forth herein are complied *
* with.
*******************************************************************************
* initializing program of multiple database
SET TALK OFF
SET HEADING OFF
SET SCOREBOARD OFF
SET SAFETY OFF
SET DELIMITER ON
SET INTENSITY OFF
SET DELIMITER TO '[]'
PUBL more, first, dr, dconame, clipper, moveit, account, keepitup, frame, line, line1
IF .NOT. clipper
SET FUNCTION 'F2' TO ' '
SET FUNCTION 'F3' TO ' '
SET FUNCTION 'F4' TO ' '
SET FUNCTION 'F5' TO ' '
SET FUNCTION 'F6' TO ' '
SET FUNCTION 'F7' TO ' '
SET FUNCTION 'F8' TO ' '
SET FUNCTION 'F9' TO ' '
SET FUNCTION 'F10' TO ' '
SET DOHISTORY ON
SET HELP OFF
ON ERROR SUSPEND
ON ESCAPE suspend
ENDI
SET PROCEDURE TO PROC
line = REPLICATE(CHR(205),80)
line1 = REPLICATE(CHR(205),78)
frame = CHR(201)+CHR(205)+CHR(187)+CHR(186)+CHR(188)+;
CHR(205)+CHR(200)+CHR(186)
* must have correct date information
DO WHIL SUBSTR(DTOC(DATE()),7,2) = '80'
CLEA
! DATE
! TIME
ENDD
IF .NOT. file ("MANAGE.DAT")
DO INIT
ENDI .NOT. file
REST from manage.dat additive
IF clipper
IF .NOT. file ("CODE.NTX")
CLEA
@ 10,10 SAY 'I must create index files for Clipper.'
@ 11,10 SAY 'Please be patient for a few moments'
@ 12,00 SAY ' '
SELE A
USE &dr.:build
INDE ON bcode TO &dr.:code
SELE B
USE &dr.:tenant
INDE on bcode to &dr.:codea
SELE C
USE &dr.:account
INDE ON SUBSTR(data,7,4) +date + SUBSTR(data,5,2) TO &dr.:account
SELE D
USE &dr.:CHART
INDE on acctno TO &dr.:chart
ENDI
ELSE
IF .NOT. file ("CODE.NDX")
CLEA
@ 10,10 SAY 'I must create index files for dBase.'
@ 11,10 SAY 'I will keep you posted'
@ 12,00 SAY ' '
SET ECHO ON
SET TALK ON
SELE A
USE &dr.:build
INDE ON bcode TO &dr.:code
SELE B
USE &dr.:tenant
INDE on bcode to &dr.:codea
SELE C
USE &dr.:account
INDE ON SUBSTR(data,7,4) +date + SUBSTR(data,5,2) TO &dr.:account
SELE D
USE &dr.:CHART
INDE on acctno TO &dr.:chart
SET TALK OFF
SET ECHO OFF
ENDI
ENDI clipper
SET PROC TO proc
CLEA
IF clipper
@ 1,0, 16, 79 BOX frame
@ 3,3, 14, 74 BOX frame
ELSE
@ 01,0 TO 16,79 double
@ 03,3 TO 14,74 double
ENDI clipper
@ 05,19 SAY 'AMATEUR COMPUTER GROUP OF NEW JERSEY'
@ 7,18 SAY 'SIG/M P R O P E R T Y M A N A G E R'
@ 9,20 SAY 'A dBASEIII DATA MANAGEMENT PROGRAM'
@ 10,25 SAY 'FOR TENANTED REAL ESTATE'
@ 11,35 SAY 'by Stephen M. Leon'
@ 13,40 SAY 'Vers 2.0 June 1986 (C) 1984,5,6'
STOR 'Y' TO goahead
@ 18,07 SAY "ARE YOU AGREEABLE TO THE TERMS OF THE COPYRIGHT LICENSING AGREEMENT"
@ 19,07 SAY "AS SET FORTH IN THE FILE 'MANAGE.PRG' ? "
@ 19,65 GET goahead PICTURE '!'
READ
DO WHIL AT(goahead, 'YN') = 0
@ 19,65 GET goahead PICTURE '!'
READ
ENDD WHILE goahead
IF goahead = 'N'
QUIT
ENDI
* set up initial database file
SELE A
USE &dr.:build
SET INDEX TO &dr.:code
* set up forever loop for program
DO WHIL .t.
STOR '?' TO comman
CLEA
IF clipper
@ 0,0, 22, 79 BOX frame
@ 4,1 SAY line1
@ 19,1 SAY line1
ELSE
@ 0,0 TO 4,79
@ 0,0 TO 19,79
@ 0,0 TO 22,79 DOUBLE
ENDI
@ 20,5 SAY 'Please select one of the above options. You may also leave this menu'
@ 21,5 SAY "by typing 'Q' and get on-line HELP by typing '?'."
@ 2,06 SAY DCONAME + ' - MAIN MENU'
@ 2,65 SAY DTOC(date())
@ 7,26 SAY "A. Accounting Database"
@ 8,26 SAY "B. Building Database"
@ 9,26 SAY "C. Tenant Database"
@ 10,26 SAY "D. Database Maintenance"
@ 11,26 SAY "E. Help"
@ 12,26 SAY "F. Reports"
@ 13,26 SAY "G. Quit to dBASE"
@ 14,26 SAY "H. Exit to operating system"
@ 17,23 SAY "PLEASE SELECT ONE OF THE OPTIONS"
@ 17,58 GET comman PICTURE '!'
READ
DO WHIL AT(COMMAN, 'ABCDEFGH?Q') = 0
STOR '?' TO comman
@ 17,58 GET comman PICTURE '!'
READ
ENDD
DO CASE
CASE COMMAN = 'A'
SELE C
USE &dr.:account
DO account
CASE COMMAN = 'B'
SELE A
USE &dr.:build INDEX &dr.:code
DO build
CASE COMMAN = 'C'
SELE B
USE &dr.:tenant INDEX &dr.:codea
DO tenant
CASE COMMAN = 'D'
DO maintain
CASE COMMAN = 'F'
DO report
CASE COMMAN = 'E' .OR. COMMAN = '?'
CLEA
TEXT
M A I N M E N U H E L P F I L E
We have tried to make this program as simple and as straight forward as is
possible. There is no separate documentation - but at any point in the pro-
gram where a '?' prompt appears we have built in a help menu to explain the
various options. You also may want to print out the opening program module
(a